
****************************************************************************************************************************************		
****************************** Social Contagion of Ethnic Hostility (Bauer et al. 2018) *********************************************
******************************** Replication File *******************************************************************
*****************************************************************************************************************************************

*Please cite the data as:
*Bauer, Michal; Cahlikova, Jana; Chytilova, Julie; Zelinsky, Tomas, 2018, "Replication Data for: Social Contagion of Ethnic Hostility", https://doi.org/10.7910/DVN/G651WB, Harvard Dataverse, V1, UNF:6:T4GLSAjsWkkGyddf3FgLmQ== 

***************************************************************************************************************************************		
****************************** BASIC INFO

****Change the directory here to your folder where this code and all the datafiles have been stored
cd "C:\..........\.."

*Create a folder where Tables and figures will be stored (if already there, comment out the following line)
mkdir Tables_Figures_Paper, public

****************************** 
****Datasets

****Study 1
use "Data_Social_contagion_Study1.dta", clear
*Stata 14 version 
	*Stata 12 version is also available on Harvard Dataverse (make sure you downloaded the datafile individually in the Original File Format (STATA binary)): 
	*use "Data_Social_contagion_Study1_stata12.dta", clear

****Study 2
use "Data_Social_contagion_Study2_wide.dta", clear
*in the wide dataset, there are 4 observations per subject, corresponding to the 4 situations (SAME/OTHER*NO_PEER/DESTRUCTIVE_PEER) 
*in the wide dataset, Social norms Task 1 estimate and the 10 Task 2 estimates are then included in the same observation (row)
*Stata 14 version
	*Stata 12 version is also available on Harvard Dataverse (make sure you downloaded the datafile individually in the Original File Format (STATA binary)): 
	*use "Data_Social_contagion_Study2_wide_stata12.dta", clear


use "Data_Social_contagion_Study2_long.dta", clear
*in the long dataset, each estimate (Task 1 and each estimate in Task 2) is a separate observations
*there are then 11 observations per subject per situation (SAME/OTHER*NO_PEER/DESTRUCTIVE_PEER) - Task 1 estimate and the 10 Task 2 estimates
*in the analysis, we cluster standard errors on the subject level
*Stata 14 version
	*Stata 12 version is also available on Harvard Dataverse (make sure you downloaded the datafile individually in the Original File Format (STATA binary)): 
	*use "Data_Social_contagion_Study2_long_stata12.dta", clear

****************************** 
****Problems
*If you experience issues with this do.file or the datasets, send an email to: jana.cahlikova@tax.mpg.de

***************************************************************************************************************************************		
******************************Study 1 Check: Generating variables indicating social environment treatments
***************************************************************************************************************************************		
*These variables are already generated in Data_Social_contagion_Study1.dta dataset - this is just to show how

use "Data_Social_contagion_Study1.dta", clear

drop INDIVIDUAL NO_PEER Treatment_Per2 Treatment_Per3 DESTRUCTIVE_PEER PEACEFUL_PEER COOPERATIVE_PEER NONCOOPERATIVE_PEER signal_mixed_JD signal_mixed_PD OTHER_DESTRUCTIVE_PEER OTHER_PEACEFUL_PEER OTHER_COOPERATIVE_PEER OTHER_NONCOOPERATIVE_PEER

		tab Treatment_PEERS		
		
		gen INDIVIDUAL=0
		replace INDIVIDUAL=1 if Treatment_PEERS==1
		gen NO_PEER=0
		replace NO_PEER=1 if Treatment_PEERS==2	
		gen Treatment_Per2=0
		replace Treatment_Per2=1 if Treatment_PEERS==3
		gen Treatment_Per3=0
		replace Treatment_Per3=1 if Treatment_PEERS==4
			
		gen DESTRUCTIVE_PEER=0
		replace DESTRUCTIVE_PEER=1 if (Treatment_Per2==1 & Per1_JDD1==1) | (Treatment_Per3==1 & Per1_JDD1==1 & Per2_JDD1==1)
		gen PEACEFUL_PEER=0
		replace PEACEFUL_PEER=1 if (Treatment_Per2==1 & Per1_JDD1==0) | (Treatment_Per3==1 & (Per1_JDD1==0 | Per2_JDD1==0))
			tab DESTRUCTIVE_PEER 
			tab PEACEFUL_PEER 
		
		gen COOPERATIVE_PEER=0
		replace COOPERATIVE_PEER=1 if (Treatment_Per2==1 & Per1_PDD1==1) | (Treatment_Per3==1 & Per1_PDD1==1 & Per2_PDD1==1)
		gen NONCOOPERATIVE_PEER=0
		replace NONCOOPERATIVE_PEER=1 if (Treatment_Per2==1 & Per1_PDD1==0) | (Treatment_Per3==1 & (Per1_PDD1==0 | Per2_PDD1==0))
			tab COOPERATIVE_PEER 
			tab NONCOOPERATIVE_PEER 		
		
		gen signal_mixed_JD=0
		replace signal_mixed_JD=1 if (Treatment_Per3==1 & Per1_JDD1==0 & Per2_JDD1==1) | (Treatment_Per3==1 & Per1_JDD1==1 & Per2_JDD1==0)
        gen signal_mixed_PD=0
		replace signal_mixed_PD=1 if (Treatment_Per3==1 & (Per1_PDD1==0 | Per2_PDD1==1)) | (Treatment_Per3==1 & (Per1_PDD1==1 | Per2_PDD1==0))
			tab signal_mixed_JD 
			tab signal_mixed_PD 
		
			tab Treatment_PEERS DESTRUCTIVE_PEER
			tab Treatment_PEERS PEACEFUL_PEER
			tab Treatment_PEERS NO_PEER
			tab Treatment_PEERS INDIVIDUAL

			tab Treatment_Per2 DESTRUCTIVE_PEER
			tab Treatment_Per2 PEACEFUL_PEER
			
			tab Treatment_Per3 DESTRUCTIVE_PEER
			tab Treatment_Per3 PEACEFUL_PEER		
	
		gen OTHER_DESTRUCTIVE_PEER=DESTRUCTIVE_PEER*OTHER
		gen OTHER_PEACEFUL_PEER=PEACEFUL_PEER*OTHER
		
		gen OTHER_COOPERATIVE_PEER=COOPERATIVE_PEER*OTHER
		gen OTHER_NONCOOPERATIVE_PEER=NONCOOPERATIVE_PEER*OTHER

			label variable Treatment_Per2 "Second decision-maker, observed one peers prior to deciding"
			label variable Treatment_Per3 "Third decision-maker, observed two peers prior to deciding"
			label variable NO_PEER "First decision-maker, did not see other peers prior to deciding"
			label variable INDIVIDUAL "Decision-maker was deciding individually, in complete isolation from others"
			label variable DESTRUCTIVE_PEER "Decision-maker observed consistently destructive peers (one or two) prior to deciding"
			label variable PEACEFUL_PEER "Decision-maker observed at least one non-destructive peer prior to deciding"
			label variable COOPERATIVE_PEER "Decision-maker observed consistently cooperative peers (one or two) prior to deciding"
			label variable NONCOOPERATIVE_PEER "Decision-maker observed at least one non-cooperative peer prior to deciding"
			label variable OTHER_DESTRUCTIVE_PEER "OTHER*DESTRUCTIVE_PEER interaction"
			label variable OTHER_PEACEFUL_PEER "OTHER*PEACEFUL_PEER interaction"
			label variable OTHER_COOPERATIVE_PEER  "OTHER*COOPERATIVE_PEER interaction"
			label variable OTHER_NONCOOPERATIVE_PEER  "OTHER*NONCOOPERATIVE_PEER interaction"
			label variable signal_mixed_JD "Third decision-maker who observed one destructive and one non-destructive peer"
			label variable signal_mixed_PD "Third decision-maker who observed one cooperative and one non-cooperative peer"



***************************************************************************************************************************************		
****************************** FIGURES ***********************************************		
*****************************************************************************************************************************************

*are located in the end of the file (starting line 999)

	
***************************************************************************************************************************************		
****************************** TABLE 1 ***********************************************		
*****************************************************************************************************************************************
			
		use "Data_Social_contagion_Study1.dta", clear


			reg JDD1 OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER  Female grade9 if (Treatment_Per2==1 | Treatment_Per3==1), robust
			outreg2 using "Tables_Figures_Paper\Table1.xls", replace dec(2) stats(coef pval N)  bracket(pval) label
					lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
					outreg2 
			reg JDD1 OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER  Female grade9 if (Treatment_Per2==1), robust
				outreg2
					lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
					outreg2
			reg JDD1 OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER  Female grade9 if (Treatment_Per3==1), robust
				outreg2
					lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
					outreg2
					
					
***************************************************************************************************************************************		
****************************** TABLE 2 ***********************************************		
*****************************************************************************************************************************************

		use "Data_Social_contagion_Study2_long.dta", replace


					reg Norms_Task OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER  Task_num2 Female grade9, cluster(ID_subject)
						outreg2 using "Tables_Figures_Paper\Table_2.xls", replace dec(2) stats(coef pval N)  bracket(pval)
						lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
						outreg2 
					reg Norms_Task OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER Female grade9 if Norms_Task_num==1, cluster(ID_subject)
						outreg2 
						lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
						outreg2 
					reg Norms_Task OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER Female grade9 if Norms_Task_num==2, cluster(ID_subject)
						outreg2 
						lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
						outreg2 
					reg Norms_Task_appropriate OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER  Task_num2 Female grade9, cluster(ID_subject)
						outreg2 
						lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
						outreg2 
					reg Norms_Task_appropriate OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER Female grade9 if Norms_Task_num==1, cluster(ID_subject)
						outreg2 
						lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
						outreg2 
					reg Norms_Task_appropriate OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER Female grade9 if Norms_Task_num==2, cluster(ID_subject)
						outreg2 
						lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
						outreg2 									
	
		

***************************************************************************************************************************************		
****************************** Table S1. Descriptive statistics and randomization checks ************************************************		
*****************************************************************************************************************************************


	use "Data_Social_contagion_Study1.dta", clear


*****(columns 1-6): check randomization across different treatments in the Joy of Destruction Game 
*keeping both observations (SAME and OTHER condition) per person as signal_destructive is condition-specific (we control for the OTHER condition)
			

	***Gender
		sum Female if DESTRUCTIVE_PEER==1 
		sum Female if PEACEFUL_PEER==1
		sum Female if NO_PEER==1
		sum Female if INDIVIDUAL==1
	
		reg Female DESTRUCTIVE_PEER OTHER if (Treatment_Per2==1|Treatment_Per3==1)
		outreg2 using "Tables_Figures_Paper\TableS1_Randomization.xls", replace dec(2) stats(coef pval N) adds(Prob > F, e(p)) bracket(pval) label

		reg Female NO_PEER DESTRUCTIVE_PEER PEACEFUL_PEER OTHER
		outreg2 using "Tables_Figures_Paper\TableS1_Randomization.xls", append dec(2) stats(coef pval N) adds(Prob > F, e(p)) bracket(pval) label

	****Age
		sum Age if DESTRUCTIVE_PEER==1
		sum Age if PEACEFUL_PEER==1
		sum Age if NO_PEER==1
		sum Age if INDIVIDUAL==1
	
		reg Age DESTRUCTIVE_PEER OTHER if (Treatment_Per2==1|Treatment_Per3==1)
		outreg2 using "Tables_Figures_Paper\TableS1_Randomization.xls", append dec(2) stats(coef pval N) adds(Prob > F, e(p)) bracket(pval) label
		reg Age NO_PEER DESTRUCTIVE_PEER PEACEFUL_PEER OTHER
		outreg2 using "Tables_Figures_Paper\TableS1_Randomization.xls", append dec(2) stats(coef pval N) adds(Prob > F, e(p)) bracket(pval) label
	
	****Cognitive skills
		sum Quiz_total if DESTRUCTIVE_PEER==1
		sum Quiz_total if PEACEFUL_PEER==1
		sum Quiz_total if NO_PEER==1
		sum Quiz_total if INDIVIDUAL==1
	
		reg Quiz_total DESTRUCTIVE_PEER OTHER if (Treatment_Per2==1|Treatment_Per3==1)
		outreg2 using "Tables_Figures_Paper\TableS1_Randomization.xls", append dec(2) stats(coef pval N) adds(Prob > F, e(p)) bracket(pval) label
		reg Quiz_total NO_PEER DESTRUCTIVE_PEER PEACEFUL_PEER OTHER
		outreg2 using "Tables_Figures_Paper\TableS1_Randomization.xls", append dec(2) stats(coef pval N) adds(Prob > F, e(p)) bracket(pval) label
		
	****Siblings
		sum Siblings if DESTRUCTIVE_PEER==1
		sum Siblings if PEACEFUL_PEER==1
		sum Siblings if NO_PEER==1
		sum Siblings if INDIVIDUAL==1
	
		reg Siblings DESTRUCTIVE_PEER OTHER if (Treatment_Per2==1|Treatment_Per3==1)
		outreg2 using "Tables_Figures_Paper\TableS1_Randomization.xls", append dec(2) stats(coef pval N) adds(Prob > F, e(p)) bracket(pval) label
		reg Siblings NO_PEER DESTRUCTIVE_PEER PEACEFUL_PEER OTHER
		outreg2 using "Tables_Figures_Paper\TableS1_Randomization.xls", append dec(2) stats(coef pval N) adds(Prob > F, e(p)) bracket(pval) label
				
	****Mother unemployed
		sum MotherUnemployed if DESTRUCTIVE_PEER==1
		sum MotherUnemployed if PEACEFUL_PEER==1
		sum MotherUnemployed if NO_PEER==1
		sum MotherUnemployed if INDIVIDUAL==1
	
		reg MotherUnemployed DESTRUCTIVE_PEER OTHER if (Treatment_Per2==1|Treatment_Per3==1)
		outreg2 using "Tables_Figures_Paper\TableS1_Randomization.xls", append dec(2) stats(coef pval N) adds(Prob > F, e(p)) bracket(pval) label
		reg MotherUnemployed NO_PEER DESTRUCTIVE_PEER PEACEFUL_PEER OTHER
		outreg2 using "Tables_Figures_Paper\TableS1_Randomization.xls", append dec(2) stats(coef pval N) adds(Prob > F, e(p)) bracket(pval) label
					
	****Father unemployed
		sum FatherUnemployed if DESTRUCTIVE_PEER==1
		sum FatherUnemployed if PEACEFUL_PEER==1
		sum FatherUnemployed if NO_PEER==1
		sum FatherUnemployed if INDIVIDUAL==1
	
		reg FatherUnemployed DESTRUCTIVE_PEER OTHER if (Treatment_Per2==1|Treatment_Per3==1)
		outreg2 using "Tables_Figures_Paper\TableS1_Randomization.xls", append dec(2) stats(coef pval N) adds(Prob > F, e(p)) bracket(pval) label
		reg FatherUnemployed NO_PEER DESTRUCTIVE_PEER PEACEFUL_PEER OTHER
		outreg2 using "Tables_Figures_Paper\TableS1_Randomization.xls", append dec(2) stats(coef pval N) adds(Prob > F, e(p)) bracket(pval) label
		
		
	****Education Mother: high school
		sum Educ_Mother_Secondary if DESTRUCTIVE_PEER==1
        sum Educ_Mother_Secondary if PEACEFUL_PEER==1
		sum Educ_Mother_Secondary if NO_PEER==1
		sum Educ_Mother_Secondary if INDIVIDUAL==1
	
		reg Educ_Mother_Secondary DESTRUCTIVE_PEER OTHER if (Treatment_Per2==1|Treatment_Per3==1)
		outreg2 using "Tables_Figures_Paper\TableS1_Randomization.xls", append dec(2) stats(coef pval N) adds(Prob > F, e(p)) bracket(pval) label
		reg Educ_Mother_Secondary NO_PEER DESTRUCTIVE_PEER PEACEFUL_PEER OTHER
		outreg2 using "Tables_Figures_Paper\TableS1_Randomization.xls", append dec(2) stats(coef pval N) adds(Prob > F, e(p)) bracket(pval) label
		

	****Education Mother: university
		sum Educ_Mother_Tertiary if DESTRUCTIVE_PEER==1
		sum Educ_Mother_Tertiary if PEACEFUL_PEER==1
		sum Educ_Mother_Tertiary if NO_PEER==1
		sum Educ_Mother_Tertiary if INDIVIDUAL==1
	
		reg Educ_Mother_Tertiary DESTRUCTIVE_PEER OTHER if (Treatment_Per2==1|Treatment_Per3==1)
		outreg2 using "Tables_Figures_Paper\TableS1_Randomization.xls", append dec(2) stats(coef pval N) adds(Prob > F, e(p)) bracket(pval) label
		reg Educ_Mother_Tertiary NO_PEER DESTRUCTIVE_PEER PEACEFUL_PEER OTHER
		outreg2 using "Tables_Figures_Paper\TableS1_Randomization.xls", append dec(2) stats(coef pval N) adds(Prob > F, e(p)) bracket(pval) label
		
	****Education Father: high school
		sum Educ_Father_Secondary if DESTRUCTIVE_PEER==1
		sum Educ_Father_Secondary if PEACEFUL_PEER==1
		sum Educ_Father_Secondary if NO_PEER==1
		sum Educ_Father_Secondary if INDIVIDUAL==1
	
		reg Educ_Father_Secondary DESTRUCTIVE_PEER OTHER if (Treatment_Per2==1|Treatment_Per3==1)
		outreg2 using "Tables_Figures_Paper\TableS1_Randomization.xls", append dec(2) stats(coef pval N) adds(Prob > F, e(p)) bracket(pval) label
		reg Educ_Father_Secondary NO_PEER DESTRUCTIVE_PEER PEACEFUL_PEER OTHER
		outreg2 using "Tables_Figures_Paper\TableS1_Randomization.xls", append dec(2) stats(coef pval N) adds(Prob > F, e(p)) bracket(pval) label

	****Education Father: university
		sum Educ_Father_Tertiary if DESTRUCTIVE_PEER==1
		sum Educ_Father_Tertiary if PEACEFUL_PEER==1
		sum Educ_Father_Tertiary if NO_PEER==1
		sum Educ_Father_Tertiary if INDIVIDUAL==1
	
		reg Educ_Father_Tertiary DESTRUCTIVE_PEER OTHER if (Treatment_Per2==1|Treatment_Per3==1)
		outreg2 using "Tables_Figures_Paper\TableS1_Randomization.xls", append dec(2) stats(coef pval N) adds(Prob > F, e(p)) bracket(pval) label
		reg Educ_Father_Tertiary NO_PEER DESTRUCTIVE_PEER PEACEFUL_PEER OTHER
		outreg2 using "Tables_Figures_Paper\TableS1_Randomization.xls", append dec(2) stats(coef pval N) adds(Prob > F, e(p)) bracket(pval) label

	****Car
		sum Car if DESTRUCTIVE_PEER==1
        sum Car if PEACEFUL_PEER==1
		sum Car if NO_PEER==1
		sum Car if INDIVIDUAL==1
	
		reg Car DESTRUCTIVE_PEER OTHER if (Treatment_Per2==1|Treatment_Per3==1)
		outreg2 using "Tables_Figures_Paper\TableS1_Randomization.xls", append dec(2) stats(coef pval N) adds(Prob > F, e(p)) bracket(pval) label
		reg Car NO_PEER DESTRUCTIVE_PEER PEACEFUL_PEER OTHER
		outreg2 using "Tables_Figures_Paper\TableS1_Randomization.xls", append dec(2) stats(coef pval N) adds(Prob > F, e(p)) bracket(pval) label

	****Computer
		sum Computer if DESTRUCTIVE_PEER==1
        sum Computer if PEACEFUL_PEER==1
		sum Computer if NO_PEER==1
		sum Computer if INDIVIDUAL==1
	
		reg Computer DESTRUCTIVE_PEER OTHER if (Treatment_Per2==1|Treatment_Per3==1)
		outreg2 using "Tables_Figures_Paper\TableS1_Randomization.xls", append dec(2) stats(coef pval N) adds(Prob > F, e(p)) bracket(pval) label
		reg Computer NO_PEER DESTRUCTIVE_PEER PEACEFUL_PEER OTHER
		outreg2 using "Tables_Figures_Paper\TableS1_Randomization.xls", append dec(2) stats(coef pval N) adds(Prob > F, e(p)) bracket(pval) label
		
	****Television
		sum Television if DESTRUCTIVE_PEER==1
        sum Television if PEACEFUL_PEER==1
		sum Television if NO_PEER==1
		sum Television if INDIVIDUAL==1
	
		reg Television DESTRUCTIVE_PEER OTHER if (Treatment_Per2==1|Treatment_Per3==1)
		outreg2 using "Tables_Figures_Paper\TableS1_Randomization.xls", append dec(2) stats(coef pval N) adds(Prob > F, e(p)) bracket(pval) label
		reg Television NO_PEER DESTRUCTIVE_PEER PEACEFUL_PEER OTHER
		outreg2 using "Tables_Figures_Paper\TableS1_Randomization.xls", append dec(2) stats(coef pval N) adds(Prob > F, e(p)) bracket(pval) label

	****Tablet
		sum Tablet if DESTRUCTIVE_PEER==1
        sum Tablet if PEACEFUL_PEER==1
		sum Tablet if NO_PEER==1
		sum Tablet if INDIVIDUAL==1
	
		reg Tablet DESTRUCTIVE_PEER OTHER if (Treatment_Per2==1|Treatment_Per3==1)
		outreg2 using "Tables_Figures_Paper\TableS1_Randomization.xls", append dec(2) stats(coef pval N) adds(Prob > F, e(p)) bracket(pval) label
		reg Tablet NO_PEER DESTRUCTIVE_PEER PEACEFUL_PEER OTHER
		outreg2 using "Tables_Figures_Paper\TableS1_Randomization.xls", append dec(2) stats(coef pval N) adds(Prob > F, e(p)) bracket(pval) label
		
***************************************************************************************************************************************		
****************************** Table S2. Choices in the Joy of Destruction game, means, the effect of peer behavior *********************	
*****************************************************************************************************************************************

	use "Data_Social_contagion_Study1.dta", clear

			****Column 1
			ttest JDD1 if NO_PEER==1, by(OTHER) 
			tab JDD1 OTHER if NO_PEER==1, chi2  
			
			****Column 2
			ttest JDD1 if DESTRUCTIVE_PEER==1 & (Treatment_Per2==1 | Treatment_Per3==1), by(OTHER)
			tab JDD1 OTHER if DESTRUCTIVE_PEER==1 & (Treatment_Per2==1 | Treatment_Per3==1), chi2 
			
			****Column 3
			ttest JDD1 if PEACEFUL_PEER==1 & (Treatment_Per2==1 | Treatment_Per3==1), by(OTHER) 
			tab JDD1 OTHER if PEACEFUL_PEER==1 & (Treatment_Per2==1 | Treatment_Per3==1), chi2 

			****Column 4
			ttest JDD1 if (Treatment_Per2==1 | Treatment_Per3==1) & OTHER==1, by(DESTRUCTIVE_PEER) 
			tab JDD1 DESTRUCTIVE_PEER if (Treatment_Per2==1 | Treatment_Per3==1) & OTHER==1, chi2 
			ttest JDD1 if (Treatment_Per2==1 | Treatment_Per3==1) & OTHER==0, by(DESTRUCTIVE_PEER) 
			tab JDD1 DESTRUCTIVE_PEER if (Treatment_Per2==1 | Treatment_Per3==1) & OTHER==0, chi2 

			****Column 5
			ttest JDD1 if DESTRUCTIVE_PEER==1 & Treatment_Per2==1, by(OTHER)
			tab JDD1 OTHER if DESTRUCTIVE_PEER==1 & Treatment_Per2==1, chi2 
			
			****Column 6
			ttest JDD1 if PEACEFUL_PEER==1 & Treatment_Per2==1, by(OTHER) 
			tab JDD1 OTHER if PEACEFUL_PEER==1 & Treatment_Per2==1, chi2 
			
			****Column 7
			ttest JDD1 if Treatment_Per2==1 & OTHER==1, by(DESTRUCTIVE_PEER) 
			tab JDD1 DESTRUCTIVE_PEER if Treatment_Per2==1 & OTHER==1, chi2 
			ttest JDD1 if Treatment_Per2==1 & OTHER==0, by(DESTRUCTIVE_PEER) 
			tab JDD1 DESTRUCTIVE_PEER if Treatment_Per2==1 & OTHER==0, chi2 

			****Column 8
			ttest JDD1 if DESTRUCTIVE_PEER==1 & Treatment_Per3==1, by(OTHER)
			tab JDD1 OTHER if DESTRUCTIVE_PEER==1 & Treatment_Per3==1, chi2 exact
			
			****Column 9		
			ttest JDD1 if PEACEFUL_PEER==1 & Treatment_Per3==1, by(OTHER) 
			tab JDD1 OTHER if PEACEFUL_PEER==1 & Treatment_Per3==1, chi2 
		
			****Column 10
			ttest JDD1 if Treatment_Per3==1 & OTHER==1, by(DESTRUCTIVE_PEER) 
			tab JDD1 DESTRUCTIVE_PEER if Treatment_Per3==1 & OTHER==1, chi2 exact
			ttest JDD1 if Treatment_Per3==1 & OTHER==0, by(DESTRUCTIVE_PEER) 
			tab JDD1 DESTRUCTIVE_PEER if Treatment_Per3==1 & OTHER==0, chi2 
			

***************************************************************************************************************************************		
****************************** Table S3. Third decision-makers, observing a mixed signal **********************************************	
*****************************************************************************************************************************************

	use "Data_Social_contagion_Study1.dta", clear

			****Column 1
			ttest JDD1 if DESTRUCTIVE_PEER==1 & Treatment_Per3==1 , by(OTHER)
			tab JDD1 OTHER if DESTRUCTIVE_PEER==1 & Treatment_Per3==1, chi2 exact
			
			****Column 2		
			ttest JDD1 if PEACEFUL_PEER==1 & Treatment_Per3==1 & signal_mixed_JD==1, by(OTHER) 
			tab JDD1 OTHER if PEACEFUL_PEER==1 & Treatment_Per3==1 & signal_mixed_JD==1, chi2 exact
			
			****Column 3		
			ttest JDD1 if PEACEFUL_PEER==1 & Treatment_Per3==1 & signal_mixed_JD==0, by(OTHER) 
			tab JDD1 OTHER if PEACEFUL_PEER==1 & Treatment_Per3==1 & signal_mixed_JD==0, chi2 exact
		
			****Column 4
			ttest JDD1 if Treatment_Per3==1 & OTHER==1 & (DESTRUCTIVE_PEER==1 | (PEACEFUL_PEER==1 & signal_mixed_JD==0)), by(DESTRUCTIVE_PEER) 
			tab JDD1 DESTRUCTIVE_PEER if Treatment_Per3==1 & OTHER==1 &(DESTRUCTIVE_PEER==1 | (PEACEFUL_PEER==1 & signal_mixed_JD==0)), chi2 exact
			ttest JDD1 if Treatment_Per3==1 & OTHER==0 & (DESTRUCTIVE_PEER==1 | (PEACEFUL_PEER==1 & signal_mixed_JD==0)), by(DESTRUCTIVE_PEER) 
			tab JDD1 DESTRUCTIVE_PEER if Treatment_Per3==1 & OTHER==0 &(DESTRUCTIVE_PEER==1 | (PEACEFUL_PEER==1 & signal_mixed_JD==0)), chi2 exact
			
			****Column 5
			ttest JDD1 if Treatment_Per3==1 & OTHER==1 & PEACEFUL_PEER==1, by(signal_mixed_JD) 
			tab JDD1 signal_mixed_JD if Treatment_Per3==1 & OTHER==1 & PEACEFUL_PEER==1, chi2 exact
			ttest JDD1 if Treatment_Per3==1 & OTHER==0 & PEACEFUL_PEER==1, by(signal_mixed_JD) 
			tab JDD1 signal_mixed_JD if Treatment_Per3==1 & OTHER==0 & PEACEFUL_PEER==1, chi2 exact	
			

		
********************************************************************************************************************************************************************			
****************************** Table S4. The effect of peer behavior on the prevalence of destructive choices (Joy of Destruction game), robustness checks
**********************************************************************************************************************************************************************	

	use "Data_Social_contagion_Study1.dta", clear

		global x_Experimenters Experimenter1 Experimenter2 Experimenter3 Experimenter5
	
		quietly tabulate School, generate(dum_School)
		
		global x_Schools  dum_School2 dum_School3 dum_School4 dum_School5 dum_School6 dum_School7 dum_School8 dum_School9 dum_School10 dum_School11 dum_School12 dum_School13

	****************1) Only the first-implemented condition (mimicking a between-subject design)
			reg JDD1 OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER  Female grade9 if IdentityCondtion_PlayedFirst==1 & (Treatment_Per2==1 | Treatment_Per3==1), robust
			outreg2 using "Tables_Figures_Paper\TableS4_Robustness.xls", replace dec(2) stats(coef pval N)  bracket(pval) label
				lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
					outreg2 
			
	****************2) Controlling for design features (order effects and experimenter fixed effects)
			reg JDD1 OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER  Female grade9 $x_Experimenters OrderGames_PDfirst Order_OTHERfirst if (Treatment_Per2==1 | Treatment_Per3==1), robust
			outreg2 
				lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
					outreg2 
 
		
	****************3) Excluding subjects with imperfect understanding (only JDCQ==4)
			reg JDD1 OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER  Female grade9 if JDCQ==4 & (Treatment_Per2==1 | Treatment_Per3==1), robust
			outreg2 
				lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
					outreg2 
	
	****************5) Controlling for school fixed effects
			reg JDD1 OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER  Female grade9 $x_Schools  if (Treatment_Per2==1 | Treatment_Per3==1), robust
			outreg2  
			lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
					outreg2 	
	
		
	****************4) Probit
	probit JDD1 OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER  Female grade9 if (Treatment_Per2==1 | Treatment_Per3==1)
	mfx
	outreg2 using "Tables_Figures_Paper\TableAX_Robustness.xls", append dec(2) mfx stats(coef pval N)  bracket(pval) label



***************************************************************************************************************************************************************		
******************************Table S5. The effect of peer behavior on the prevalence of destructive choices (Joy of Destruction game), heterogeneity analysis	
*****************************************************************************************************************************************************************	
	
use "Data_Social_contagion_Study1.dta", clear



***Kosice/Presov region
			reg JDD1 OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER Female grade9 if Region_Presov==0 & (Treatment_Per2==1 | Treatment_Per3==1), robust
				outreg2 using "Tables_Figures_Paper\TableS5_Heterogeneity.xls", replace dec(2) stats(coef pval N)  bracket(pval) label
				lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
				outreg2
			reg JDD1 OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER  Female grade9 if Region_Presov==1 & (Treatment_Per2==1 | Treatment_Per3==1), robust
				outreg2 
				lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
				outreg2
		***smaller/larger towns		
			reg JDD1 OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER Female grade9 if village_bigger==0 & (Treatment_Per2==1 | Treatment_Per3==1), robust
				outreg2 
				lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
				outreg2
			reg JDD1 OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER Female grade9 if village_bigger==1 & (Treatment_Per2==1 | Treatment_Per3==1), robust
				outreg2 
				lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
				outreg2
		
	***lower share of Roma/higher share of Roma in the town
			reg JDD1 OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER  Female grade9 if village_more_Roma==0 & (Treatment_Per2==1 | Treatment_Per3==1), robust
				outreg2 
				lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
				outreg2
			reg JDD1 OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER  Female grade9 if village_more_Roma==1 & (Treatment_Per2==1 | Treatment_Per3==1), robust
				outreg2 
				lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
				outreg2

	****only those where at least one parent has a univesity degree (self-reported, 24% of the sample)
		****************************Panel A: Treatment_Per2 and Treatment_Per3 pooled
			reg JDD1 OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER  Female grade9 if (Treatment_Per2==1 | Treatment_Per3==1) & (Educ_Mother_Tertiary==1 | Educ_Father_Tertiary==1), robust
				outreg2 
				lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
				outreg2 
			reg JDD1 OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER  Female grade9 if (Treatment_Per2==1 | Treatment_Per3==1) & (Educ_Mother_Tertiary==0 & Educ_Father_Tertiary==0), robust
				outreg2 
				lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
				outreg2 		
					
*******************************************************************************************************************************************************************************************		
****************************** Table S6. The effect of peer behavior on the prevalence of destructive choices (Joy of Destruction game) ***********************************************		
*********************************************************************************************************************************************************************************************	

use "Data_Social_contagion_Study1.dta", clear
			

	*************Omitted group: NO PEER (first-decision maker)
			reg JDD1 OTHER_DESTRUCTIVE_PEER OTHER_PEACEFUL_PEER OTHER DESTRUCTIVE_PEER PEACEFUL_PEER  Female grade9 if INDIVIDUAL==0, robust
				outreg2 using "Tables_Figures_Paper\TableS6_Columns1_3.xls", replace dec(2) stats(coef pval N)  bracket(pval) label
				lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
				outreg2
				quietly: reg JDD1 OTHER_DESTRUCTIVE_PEER OTHER_PEACEFUL_PEER OTHER DESTRUCTIVE_PEER PEACEFUL_PEER  Female grade9 if INDIVIDUAL==0, robust
				lincomest PEACEFUL_PEER+OTHER_PEACEFUL_PEER
				outreg2
			reg JDD1 OTHER_DESTRUCTIVE_PEER OTHER_PEACEFUL_PEER OTHER DESTRUCTIVE_PEER PEACEFUL_PEER  Female grade9 if INDIVIDUAL==0 & Treatment_Per3!=1, robust
				outreg2
				lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
				outreg2
				quietly: reg JDD1 OTHER_DESTRUCTIVE_PEER OTHER_PEACEFUL_PEER OTHER DESTRUCTIVE_PEER PEACEFUL_PEER  Female grade9 if INDIVIDUAL==0 & Treatment_Per3!=1, robust
				lincomest PEACEFUL_PEER+OTHER_PEACEFUL_PEER
				outreg2
			reg JDD1 OTHER_DESTRUCTIVE_PEER OTHER_PEACEFUL_PEER OTHER DESTRUCTIVE_PEER PEACEFUL_PEER  Female grade9 if INDIVIDUAL==0 & Treatment_Per2!=1, robust
				outreg2	
				lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
				outreg2
				quietly: reg JDD1 OTHER_DESTRUCTIVE_PEER OTHER_PEACEFUL_PEER OTHER DESTRUCTIVE_PEER PEACEFUL_PEER  Female grade9 if INDIVIDUAL==0 & Treatment_Per2!=1, robust
				lincomest PEACEFUL_PEER+OTHER_PEACEFUL_PEER
				outreg2	

	*************Omitted group: INDIVIDUAL		
			reg JDD1 OTHER_DESTRUCTIVE_PEER OTHER_PEACEFUL_PEER OTHER DESTRUCTIVE_PEER PEACEFUL_PEER  Female grade9 if NO_PEER==0, robust
				outreg2 using "Tables_Figures_Paper\TableS6_Columns4_6.xls", replace dec(2) stats(coef pval N)  bracket(pval) label
				lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
				outreg2
				quietly: reg JDD1 OTHER_DESTRUCTIVE_PEER OTHER_PEACEFUL_PEER OTHER DESTRUCTIVE_PEER PEACEFUL_PEER  Female grade9 if NO_PEER==0, robust
				lincomest PEACEFUL_PEER+OTHER_PEACEFUL_PEER
				outreg2
			reg JDD1 OTHER_DESTRUCTIVE_PEER OTHER_PEACEFUL_PEER OTHER DESTRUCTIVE_PEER PEACEFUL_PEER  Female grade9 if NO_PEER==0 & Treatment_Per3!=1, robust
				outreg2
				lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
				outreg2
				quietly: reg JDD1 OTHER_DESTRUCTIVE_PEER OTHER_PEACEFUL_PEER OTHER DESTRUCTIVE_PEER PEACEFUL_PEER  Female grade9 if NO_PEER==0 & Treatment_Per3!=1, robust
				lincomest PEACEFUL_PEER+OTHER_PEACEFUL_PEER
				outreg2
			reg JDD1 OTHER OTHER_DESTRUCTIVE_PEER OTHER_PEACEFUL_PEER DESTRUCTIVE_PEER PEACEFUL_PEER  Female grade9 if NO_PEER==0 & Treatment_Per2!=1, robust
				outreg2	
				lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
				outreg2
				quietly: reg JDD1 OTHER_DESTRUCTIVE_PEER OTHER_PEACEFUL_PEER OTHER DESTRUCTIVE_PEER PEACEFUL_PEER  Female grade9 if NO_PEER==0 & Treatment_Per2!=1, robust
				lincomest PEACEFUL_PEER+OTHER_PEACEFUL_PEER
				outreg2	
				
*******************************************************************************************************************************************************************************************		
****************************** Table S7. Choices in the Prisoner's Dilemma game, means, the effect of peer behavior ***********************************************		
*********************************************************************************************************************************************************************************************	

use "Data_Social_contagion_Study1.dta", clear

			****Column 1
			ttest PDD1 if NO_PEER==1, by(OTHER) 
			tab PDD1 OTHER if NO_PEER==1, chi2 
			
			****Column 2
			ttest PDD1 if COOPERATIVE_PEER==1 & (Treatment_Per2==1 | Treatment_Per3==1), by(OTHER)
			tab PDD1 OTHER if COOPERATIVE_PEER==1 & (Treatment_Per2==1 | Treatment_Per3==1), chi2
			
			****Column 3
			ttest PDD1 if NONCOOPERATIVE_PEER==1 & (Treatment_Per2==1 | Treatment_Per3==1), by(OTHER) 
			tab PDD1 OTHER if NONCOOPERATIVE_PEER==1 & (Treatment_Per2==1 | Treatment_Per3==1), chi2

			****Column 4
			ttest PDD1 if (Treatment_Per2==1 | Treatment_Per3==1) & OTHER==1, by(COOPERATIVE_PEER) 
			tab PDD1 COOPERATIVE_PEER if (Treatment_Per2==1 | Treatment_Per3==1) & OTHER==1, chi2
			ttest PDD1 if (Treatment_Per2==1 | Treatment_Per3==1) & OTHER==0, by(COOPERATIVE_PEER) 
			tab PDD1 COOPERATIVE_PEER if (Treatment_Per2==1 | Treatment_Per3==1) & OTHER==0, chi2

			****Column 5
			ttest PDD1 if COOPERATIVE_PEER==1 & Treatment_Per2==1, by(OTHER)
			tab PDD1 OTHER if COOPERATIVE_PEER==1 & Treatment_Per2==1, chi2
			
			****Column 6
			ttest PDD1 if NONCOOPERATIVE_PEER==1 & Treatment_Per2==1, by(OTHER) 
			tab PDD1 OTHER if NONCOOPERATIVE_PEER==1 & Treatment_Per2==1, chi2
			
			****Column 7
			ttest PDD1 if Treatment_Per2==1 & OTHER==1, by(COOPERATIVE_PEER) 
			tab PDD1 COOPERATIVE_PEER if Treatment_Per2==1 & OTHER==1, chi2
			ttest PDD1 if Treatment_Per2==1 & OTHER==0, by(COOPERATIVE_PEER) 
			tab PDD1 COOPERATIVE_PEER  if Treatment_Per2==1 & OTHER==0, chi2

			****Column 8
			ttest PDD1 if COOPERATIVE_PEER==1 & Treatment_Per3==1, by(OTHER)
			tab PDD1 OTHER if COOPERATIVE_PEER==1 & Treatment_Per3==1, chi2 exact
			
			****Column 9		
			ttest PDD1 if NONCOOPERATIVE_PEER==1 & Treatment_Per3==1, by(OTHER) 
			tab PDD1 OTHER if NONCOOPERATIVE_PEER==1 & Treatment_Per3==1, chi2
		
			****Column 10
			ttest PDD1 if Treatment_Per3==1 & OTHER==1, by(COOPERATIVE_PEER) 
			tab PDD1 COOPERATIVE_PEER if Treatment_Per3==1 & OTHER==1, chi2 exact
			ttest PDD1 if Treatment_Per3==1 & OTHER==0, by(COOPERATIVE_PEER) 
			tab PDD1 COOPERATIVE_PEER if Treatment_Per3==1 & OTHER==0, chi2  exact

		
		
***************************************************************************************************************************************		
****************************** Table S8. The effect of peer behavior on prevalence of cooperative choices (Prisoner's Dilemma game)  		
*****************************************************************************************************************************************

use "Data_Social_contagion_Study1.dta", clear

		*************Omitted group: Only second and third decision-makers

			reg PDD1 OTHER COOPERATIVE_PEER OTHER_COOPERATIVE_PEER Female grade9 if (Treatment_Per2==1 | Treatment_Per3==1), robust
				outreg2 using "Tables_Figures_Paper\TableS8_Columns1_3.xls", replace dec(2) stats(coef pval N)  bracket(pval) label
				lincomest COOPERATIVE_PEER+OTHER_COOPERATIVE_PEER 
				outreg2
			reg PDD1 OTHER COOPERATIVE_PEER OTHER_COOPERATIVE_PEER Female grade9 if (Treatment_Per2==1), robust
				outreg2
				lincomest COOPERATIVE_PEER+OTHER_COOPERATIVE_PEER 
				outreg2
			reg PDD1 OTHER COOPERATIVE_PEER OTHER_COOPERATIVE_PEER Female grade9 if (Treatment_Per3==1), robust
				outreg2
				lincomest COOPERATIVE_PEER+OTHER_COOPERATIVE_PEER 
				outreg2
				
		*************Omitted group: NO PEER		
			reg PDD1 OTHER COOPERATIVE_PEER NONCOOPERATIVE_PEER OTHER_COOPERATIVE_PEER OTHER_NONCOOPERATIVE_PEER Female grade9 if INDIVIDUAL==0, robust
				outreg2 using "Tables_Figures_Paper\TableS8_Columns4_6.xls", replace dec(2) stats(coef pval N)  bracket(pval) label
				lincomest COOPERATIVE_PEER+OTHER_COOPERATIVE_PEER 
				outreg2
				quietly: reg PDD1 OTHER COOPERATIVE_PEER NONCOOPERATIVE_PEER OTHER_COOPERATIVE_PEER OTHER_NONCOOPERATIVE_PEER Female grade9 if INDIVIDUAL==0, robust
				lincomest NONCOOPERATIVE_PEER+OTHER_NONCOOPERATIVE_PEER
				outreg2
			reg PDD1 OTHER COOPERATIVE_PEER NONCOOPERATIVE_PEER OTHER_COOPERATIVE_PEER OTHER_NONCOOPERATIVE_PEER Female grade9 if INDIVIDUAL==0 & Treatment_Per3!=1, robust
				outreg2
				lincomest COOPERATIVE_PEER+OTHER_COOPERATIVE_PEER 
				outreg2
				quietly: reg PDD1 OTHER COOPERATIVE_PEER NONCOOPERATIVE_PEER OTHER_COOPERATIVE_PEER OTHER_NONCOOPERATIVE_PEER Female grade9 if INDIVIDUAL==0 & Treatment_Per3!=1, robust
				lincomest NONCOOPERATIVE_PEER+OTHER_NONCOOPERATIVE_PEER
				outreg2
			reg PDD1 OTHER COOPERATIVE_PEER NONCOOPERATIVE_PEER OTHER_COOPERATIVE_PEER OTHER_NONCOOPERATIVE_PEER Female grade9 if INDIVIDUAL==0 & Treatment_Per2!=1, robust
				outreg2
				lincomest COOPERATIVE_PEER+OTHER_COOPERATIVE_PEER 
				outreg2
				quietly: reg PDD1 OTHER COOPERATIVE_PEER NONCOOPERATIVE_PEER OTHER_COOPERATIVE_PEER OTHER_NONCOOPERATIVE_PEER Female grade9 if INDIVIDUAL==0 & Treatment_Per2!=1, robust
				lincomest NONCOOPERATIVE_PEER+OTHER_NONCOOPERATIVE_PEER
				outreg2							
			
				
								
***************************************************************************************************************************************		
****************************** Table S9. Discrimination, across social context ********************************************************		
*****************************************************************************************************************************************

use "Data_Social_contagion_Study1.dta", clear

	****************************Panel A: Joy of Destruction game
			reg JDD1 OTHER Female grade9 if NO_PEER==1, robust
			outreg2 using "Tables_Figures_Paper\TableS9_Discrimination_JDG.xls", replace dec(2) stats(coef pval N)  bracket(pval) label
			reg JDD1 OTHER Female grade9 if (Treatment_Per2==1 | Treatment_Per3==1) & DESTRUCTIVE_PEER==1, robust
			outreg2
			reg JDD1 OTHER Female grade9 if (Treatment_Per2==1 | Treatment_Per3==1) & DESTRUCTIVE_PEER==0, robust
			outreg2
			reg JDD1 OTHER Female grade9 if (Treatment_Per2==1) & DESTRUCTIVE_PEER==1, robust
			outreg2
			reg JDD1 OTHER Female grade9 if (Treatment_Per2==1 ) & DESTRUCTIVE_PEER==0, robust
			outreg2		
			reg JDD1 OTHER Female grade9 if (Treatment_Per3==1) & DESTRUCTIVE_PEER==1, robust
			outreg2
			reg JDD1 OTHER Female grade9 if (Treatment_Per3==1 ) & DESTRUCTIVE_PEER==0, robust
			outreg2
			reg JDD1 OTHER Female grade9 if INDIVIDUAL==1, robust
			outreg2
	
	****************************Panel B: Prisoner's Dilemma game
			reg PDD1 OTHER Female grade9 if NO_PEER==1, robust
			outreg2 using "Tables_Figures_Paper\TableS9_Discrimination_PDG.xls", replace dec(2) stats(coef pval N)  bracket(pval) label
			reg PDD1 OTHER Female grade9 if (Treatment_Per2==1 | Treatment_Per3==1) & COOPERATIVE_PEER==1, robust
			outreg2
			reg PDD1 OTHER Female grade9 if (Treatment_Per2==1 | Treatment_Per3==1) & COOPERATIVE_PEER==0, robust
			outreg2
			reg PDD1 OTHER Female grade9 if (Treatment_Per2==1) & COOPERATIVE_PEER==1, robust
			outreg2
			reg PDD1 OTHER Female grade9 if (Treatment_Per2==1 ) & COOPERATIVE_PEER==0, robust
			outreg2
			reg PDD1 OTHER Female grade9 if (Treatment_Per3==1) & COOPERATIVE_PEER==1, robust
			outreg2
			reg PDD1 OTHER Female grade9 if (Treatment_Per3==1 ) & COOPERATIVE_PEER==0, robust
			outreg2
			reg PDD1 OTHER Female grade9 if INDIVIDUAL==1 , robust
			outreg2
				

***************************************************************************************************************************************		
****************************** Table S10. Social appropriateness ratings of a destructive choice (Social Norms experiment)	***********	
*****************************************************************************************************************************************

		use "Data_Social_contagion_Study2_long.dta", replace

	*************Panel A: All estimates (Task 1 + Task 2)		
				tab Norms_Task if  DESTRUCTIVE_PEER==0 & OTHER==1
				tab Norms_Task if  DESTRUCTIVE_PEER==1 & OTHER==1
				tab Norms_Task if  DESTRUCTIVE_PEER==0 & OTHER==0
				tab Norms_Task if  DESTRUCTIVE_PEER==1 & OTHER==0

				tab Norms_Task DESTRUCTIVE_PEER if  OTHER==1, chi2
				tab Norms_Task DESTRUCTIVE_PEER if  OTHER==0, chi2
				

	*************Panel B: Estimates of the modal rating (Task 1)
				tab Norms_Task if Norms_Task_num==1 & DESTRUCTIVE_PEER==0 & OTHER==1
				tab Norms_Task if Norms_Task_num==1 & DESTRUCTIVE_PEER==1 & OTHER==1
				tab Norms_Task if Norms_Task_num==1 & DESTRUCTIVE_PEER==0 & OTHER==0
				tab Norms_Task if Norms_Task_num==1 & DESTRUCTIVE_PEER==1 & OTHER==0

				tab Norms_Task DESTRUCTIVE_PEER if Norms_Task_num==1 & OTHER==1, chi2
				tab Norms_Task DESTRUCTIVE_PEER if Norms_Task_num==1 & OTHER==0, chi2
				
						
	*************Panel C: Estimates of ratings of ten other subjects (Task 2)
				tab Norms_Task if Norms_Task_num==2 & DESTRUCTIVE_PEER==0 & OTHER==1
				tab Norms_Task if Norms_Task_num==2 & DESTRUCTIVE_PEER==1 & OTHER==1
				tab Norms_Task if Norms_Task_num==2 & DESTRUCTIVE_PEER==0 & OTHER==0
				tab Norms_Task if Norms_Task_num==2 & DESTRUCTIVE_PEER==1 & OTHER==0

				tab Norms_Task DESTRUCTIVE_PEER if Norms_Task_num==2 & OTHER==1, chi2
				tab Norms_Task DESTRUCTIVE_PEER if Norms_Task_num==2 & OTHER==0, chi2


***************************************************************************************************************************************		
****************************** Table S11. Means, social appropriateness of a destructive choice (Social Norms experiment)	***********	
*****************************************************************************************************************************************

		use "Data_Social_contagion_Study2_long.dta", replace
		
		*************Panel A: All estimates (Task 1 + Task 2)
		
		***Destructive choices in JDG rated as appropriate (Columns 1-3)
			*diff DESTRUCTIVE PEER-NO PEER
			ttest Norms_Task_appropriate if OTHER==1 , by(DESTRUCTIVE_PEER)
			median Norms_Task_appropriate if OTHER==1 , by(DESTRUCTIVE_PEER)
			ttest Norms_Task_appropriate if OTHER==0 , by(DESTRUCTIVE_PEER)
			median Norms_Task_appropriate if OTHER==0 , by(DESTRUCTIVE_PEER)
			*diff OTHER-SAME
			ttest Norms_Task_appropriate if DESTRUCTIVE_PEER==1 , by(OTHER)
			median Norms_Task_appropriate if DESTRUCTIVE_PEER==1 , by(OTHER)
			ttest Norms_Task_appropriate if DESTRUCTIVE_PEER==0 , by(OTHER)
			median Norms_Task_appropriate if DESTRUCTIVE_PEER==0 , by(OTHER)
		***Rating of appropriateness of destructive choices in JDG (Columns 4-6)
			*diff DESTRUCTIVE PEER-NO PEER
			ttest Norms_Task if DESTRUCTIVE_PEER==1, by(OTHER)
			ranksum Norms_Task if DESTRUCTIVE_PEER==1, by(OTHER)
			ttest Norms_Task if DESTRUCTIVE_PEER==0, by(OTHER)
			ranksum Norms_Task if DESTRUCTIVE_PEER==0, by(OTHER)
			*diff OTHER-SAME
			ttest Norms_Task if OTHER==1, by(DESTRUCTIVE_PEER)
			ranksum Norms_Task if OTHER==1, by(DESTRUCTIVE_PEER)
			ttest Norms_Task if OTHER==0, by(DESTRUCTIVE_PEER)
			ranksum Norms_Task if OTHER==0, by(DESTRUCTIVE_PEER)
	
	*************Panel B: Estimates of the modal rating (Task 1)
			
		***Destructive choices in JDG rated as appropriate (Columns 1-3)
			*diff DESTRUCTIVE PEER-NO PEER
			ttest Norms_Task_appropriate if OTHER==1 & Norms_Task_num==1, by(DESTRUCTIVE_PEER)
			median Norms_Task_appropriate if OTHER==1 & Norms_Task_num==1, by(DESTRUCTIVE_PEER)
			ttest Norms_Task_appropriate if OTHER==0 & Norms_Task_num==1, by(DESTRUCTIVE_PEER)
			median Norms_Task_appropriate if OTHER==0 & Norms_Task_num==1, by(DESTRUCTIVE_PEER)
			*diff OTHER-SAME
			ttest Norms_Task_appropriate if DESTRUCTIVE_PEER==1 & Norms_Task_num==1, by(OTHER)
			median Norms_Task_appropriate if DESTRUCTIVE_PEER==1 & Norms_Task_num==1, by(OTHER)
			ttest Norms_Task_appropriate if DESTRUCTIVE_PEER==0 & Norms_Task_num==1, by(OTHER)
			median Norms_Task_appropriate if DESTRUCTIVE_PEER==0 & Norms_Task_num==1, by(OTHER)			
		***Rating of appropriateness of destructive choices in JDG (Columns 4-6)
			*diff DESTRUCTIVE PEER-NO PEER
			ttest Norms_Task if Norms_Task_num==1 & DESTRUCTIVE_PEER==1, by(OTHER)
			ranksum Norms_Task if Norms_Task_num==1 & DESTRUCTIVE_PEER==1, by(OTHER)
			ttest Norms_Task if Norms_Task_num==1 & DESTRUCTIVE_PEER==0, by(OTHER)
			ranksum Norms_Task if Norms_Task_num==1 & DESTRUCTIVE_PEER==0, by(OTHER)
			*diff OTHER-SAME
			ttest Norms_Task if Norms_Task_num==1 & OTHER==1, by(DESTRUCTIVE_PEER)
			ranksum Norms_Task if Norms_Task_num==1 & OTHER==1, by(DESTRUCTIVE_PEER)
			ttest Norms_Task if Norms_Task_num==1 & OTHER==0, by(DESTRUCTIVE_PEER)
			ranksum Norms_Task if Norms_Task_num==1 & OTHER==0, by(DESTRUCTIVE_PEER)

	*************Panel C: Estimates of ratings of ten other subjects (Task 2)
	
		***Destructive choices in JDG rated as appropriate (Columns 1-3)
			*diff DESTRUCTIVE PEER-NO PEER
			ttest Norms_Task_appropriate if OTHER==1 & Norms_Task_num==2, by(DESTRUCTIVE_PEER)
			median Norms_Task_appropriate if OTHER==1 & Norms_Task_num==2, by(DESTRUCTIVE_PEER)
			ttest Norms_Task_appropriate if OTHER==0 & Norms_Task_num==2, by(DESTRUCTIVE_PEER)
			median Norms_Task_appropriate if OTHER==0 & Norms_Task_num==2, by(DESTRUCTIVE_PEER)
			*diff OTHER-SAME
			ttest Norms_Task_appropriate if DESTRUCTIVE_PEER==1 & Norms_Task_num==2, by(OTHER)
			median Norms_Task_appropriate if DESTRUCTIVE_PEER==1 & Norms_Task_num==2, by(OTHER)
			ttest Norms_Task_appropriate if DESTRUCTIVE_PEER==0 & Norms_Task_num==2, by(OTHER)
			median Norms_Task_appropriate if DESTRUCTIVE_PEER==0 & Norms_Task_num==2, by(OTHER)			
		***Rating of appropriateness of destructive choices in JDG (Columns 4-6)
			*diff DESTRUCTIVE PEER-NO PEER
			ttest Norms_Task if Norms_Task_num==2 & DESTRUCTIVE_PEER==1, by(OTHER)
			ranksum Norms_Task if Norms_Task_num==2 & DESTRUCTIVE_PEER==1, by(OTHER)
			ttest Norms_Task if Norms_Task_num==2 & DESTRUCTIVE_PEER==0, by(OTHER)
			ranksum Norms_Task if Norms_Task_num==2 & DESTRUCTIVE_PEER==0, by(OTHER)
			*diff OTHER-SAME
			ttest Norms_Task if Norms_Task_num==2 & OTHER==1, by(DESTRUCTIVE_PEER)
			ranksum Norms_Task if Norms_Task_num==2 & OTHER==1, by(DESTRUCTIVE_PEER)
			ttest Norms_Task if Norms_Task_num==2 & OTHER==0, by(DESTRUCTIVE_PEER)
			ranksum Norms_Task if Norms_Task_num==2 & OTHER==0, by(DESTRUCTIVE_PEER)

***************************************************************************************************************************************		
****************************** Table S12. The influence of peers on the perceptions of social norms, robustness check 1	***********	
*****************************************************************************************************************************************

		use "Data_Social_contagion_Study2_long.dta", replace

			***Panel A: Rating of appropriateness of destructive choices in JDG 
		
				*All subjects - Columns 1-3
					reg Norms_Task OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER  Task_num2 Female grade9, cluster(ID_subject)
						outreg2 using "Tables_Figures_Paper\Table_S12_PanelA.xls", replace dec(2) stats(coef pval N)  bracket(pval)
						lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
						outreg2 
					reg Norms_Task OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER Female grade9 if Norms_Task_num==1, cluster(ID_subject)
						outreg2 
						lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
						outreg2 
					reg Norms_Task OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER Female grade9 if Norms_Task_num==2, cluster(ID_subject)
						outreg2 
						lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
						outreg2 
				*Those with unimodal distribution in Task 2 (in NO PEER) - Columns 4-6
					reg Norms_Task OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER  Task_num2 Female grade9 if t2_unimodal_nopeer==1, cluster(ID_subject)
						outreg2 
						lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
						outreg2 
					reg Norms_Task OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER Female grade9 if Norms_Task_num==1 & t2_unimodal_nopeer==1, cluster(ID_subject)
						outreg2 
						lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
						outreg2 
					reg Norms_Task OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER Female grade9 if Norms_Task_num==2 & t2_unimodal_nopeer==1, cluster(ID_subject)
						outreg2 
						lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
						outreg2 
				*Those with unimodal distribution or bimodal distribution with consecutive modes in Task 2 (in NO PEER) - Columns 7-9	
					reg Norms_Task OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER  Task_num2 Female grade9 if t2_okmodal_nopeer==1, cluster(ID_subject)
						outreg2 
						lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
						outreg2 
					reg Norms_Task OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER Female grade9 if Norms_Task_num==1 & t2_okmodal_nopeer==1, cluster(ID_subject)
						outreg2 
						lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
						outreg2 
					reg Norms_Task OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER Female grade9 if Norms_Task_num==2 & t2_okmodal_nopeer==1, cluster(ID_subject)
						outreg2 
						lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
						outreg2 
						
		***Panel B: Destructive choices in JDG rated as appropriate 
				*All subjects - Columns 1-3
					reg Norms_Task_appropriate OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER  Task_num2 Female grade9, cluster(ID_subject)
						outreg2 using "Tables_Figures_Paper\Table_S12_PanelB.xls", replace dec(2) stats(coef pval N)  bracket(pval)
						lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
						outreg2 
					reg Norms_Task_appropriate OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER Female grade9 if Norms_Task_num==1, cluster(ID_subject)
						outreg2 
						lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
						outreg2 
					reg Norms_Task_appropriate OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER Female grade9 if Norms_Task_num==2, cluster(ID_subject)
						outreg2 
						lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
						outreg2 
				*Those with unimodal distribution in Task 2 (in NO PEER) - Columns 4-6
					reg Norms_Task_appropriate OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER  Task_num2 Female grade9 if t2_unimodal_nopeer==1, cluster(ID_subject)
						outreg2 
						lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
						outreg2 
					reg Norms_Task_appropriate OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER Female grade9 if Norms_Task_num==1 & t2_unimodal_nopeer==1, cluster(ID_subject)
						outreg2 
						lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
						outreg2 
					reg Norms_Task_appropriate OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER Female grade9 if Norms_Task_num==2 & t2_unimodal_nopeer==1, cluster(ID_subject)
						outreg2 
						lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
						outreg2 
				*Those with unimodal distribution or bimodal distribution with consecutive modes in Task 2 (in NO PEER) - Columns 7-9	
					reg Norms_Task_appropriate OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER  Task_num2 Female grade9 if t2_okmodal_nopeer==1, cluster(ID_subject)
						outreg2 
						lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
						outreg2 
					reg Norms_Task_appropriate OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER Female grade9 if Norms_Task_num==1 & t2_okmodal_nopeer==1, cluster(ID_subject)
						outreg2 
						lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
						outreg2 
					reg Norms_Task_appropriate OTHER_DESTRUCTIVE_PEER OTHER DESTRUCTIVE_PEER Female grade9 if Norms_Task_num==2 & t2_okmodal_nopeer==1, cluster(ID_subject)
						outreg2 
						lincomest DESTRUCTIVE_PEER+OTHER_DESTRUCTIVE_PEER
						outreg2 

***************************************************************************************************************************************		
****************************** Table S13. Means, choices and beliefs in the individual condition	*********************************	
*****************************************************************************************************************************************

use "Data_Social_contagion_Study1.dta", clear

		****Column 1: unconditional choices
			ttest JDD1 if INDIVIDUAL==1, by(OTHER) 
			tab OTHER JDD1 if INDIVIDUAL==1, chi2
			
			ttest PDD1 if INDIVIDUAL==1, by(OTHER) 
			tab PDD1 OTHER if INDIVIDUAL==1, chi2
			
	
		****Column 2-4: conditional choices
		***********************************
	preserve 
			
			reshape long JDD PDD,i(ID_subject OTHER ) j(choice_num)

			*JDD3 counterpart destructive
			*PDD2 counterpart cooperative

			*Column 2: destructive counterpart
			ttest JDD if INDIVIDUAL==1 & choice_num==3, by(OTHER)
			tab JDD OTHER if INDIVIDUAL==1 & choice_num==3, chi2
			
			*Clumn 3: peaceful counterpart
			ttest JDD if INDIVIDUAL==1 & choice_num==2, by(OTHER)
			tab JDD OTHER if INDIVIDUAL==1 & choice_num==2, chi2
		
				*Column 4: destructive vs. peaceful counterpart
				ttest JDD if (INDIVIDUAL==1 & OTHER==1 & choice_num!=1), by(choice_num)
				tab JDD choice_num if (INDIVIDUAL==1 & OTHER==1 & choice_num!=1), chi2

				ttest JDD if (INDIVIDUAL==1 & OTHER==0 & choice_num!=1), by(choice_num)
				tab JDD choice_num if (INDIVIDUAL==1 & OTHER==0 & choice_num!=1), chi2

			*Column 2: cooperative counterpart
			ttest PDD if INDIVIDUAL==1 & choice_num==2, by(OTHER)
			tab PDD OTHER if INDIVIDUAL==1 & choice_num==2, chi2
			
			*Column 3: noncooperative counterpart
			ttest PDD if INDIVIDUAL==1 & choice_num==3, by(OTHER)
			tab PDD OTHER if INDIVIDUAL==1 & choice_num==3, chi2

				*Column 4: cooperative vs. noncooperative counterpart
				ttest PDD if (INDIVIDUAL==1 & OTHER==1 & choice_num!=1), by(choice_num)
				tab PDD choice_num if (INDIVIDUAL==1 & OTHER==1 & choice_num!=1), chi2

				ttest PDD if (INDIVIDUAL==1 & OTHER==0 & choice_num!=1), by(choice_num)
				tab PDD choice_num if (INDIVIDUAL==1 & OTHER==0 & choice_num!=1), chi2
			
		restore
		***********************************

		****Column 5: beliefs
			ttest JDOD if INDIVIDUAL==1, by(OTHER) 
			tab JDOD OTHER if INDIVIDUAL==1, chi2
			
			ttest PDOD if INDIVIDUAL==1, by(OTHER) 
			tab PDOD OTHER if INDIVIDUAL==1, chi2 	
			
***************************************************************************************************************************************		
****************************** FIGURE 1 PANEL A: OVERALL PEER EFFECTS ************************************************		
*****************************************************************************************************************************************

use "Data_Social_contagion_Study1.dta", clear
set more off

***difference DESTRUCTIVE_PEER vs. PEACEFUL_PEAR

		ttest JDD1 if OTHER==0 & Treatment_Per2==1, by(DESTRUCTIVE_PEER)
		ttest JDD1 if OTHER==1 & Treatment_Per2==1, by(DESTRUCTIVE_PEER)

		ttest JDD1 if OTHER==0 & Treatment_Per3==1, by(DESTRUCTIVE_PEER)
		ttest JDD1 if OTHER==1 & Treatment_Per3==1, by(DESTRUCTIVE_PEER)

			***export values for the differences (means and standard errors)
			reg JDD1 DESTRUCTIVE_PEER if OTHER==0 & Treatment_Per2==1 
			outreg2 using "Tables_Figures_Paper\Figure_1_PanelA_values.xls", replace dec(5) stats(coef se N) level(95) noparen
			reg JDD1 DESTRUCTIVE_PEER  if OTHER==1 & Treatment_Per2==1 
			outreg2
			reg JDD1 DESTRUCTIVE_PEER if OTHER==0 & Treatment_Per3==1 
			outreg2
			reg JDD1 DESTRUCTIVE_PEER  if OTHER==1 & Treatment_Per3==1 
			outreg2


					*define graph values, using the values from the excel file above
									gen order2_help=1 if  OTHER==0 & Treatment_Per2==1 
									replace order2_help=2.25 if OTHER==1 & Treatment_Per2==1 
									replace order2_help=4.25 if  OTHER==0 & Treatment_Per3==1
									replace order2_help=5.5 if OTHER==1 & Treatment_Per3==1 
									
									*means
									gen diff_JDD1_PEER_mean = 0.28352 if (order2_help==1)
									replace diff_JDD1_PEER_mean = 0.58815 if (order2_help==2.25)
									replace diff_JDD1_PEER_mean = 0.38095 if (order2_help==4.25)
									replace diff_JDD1_PEER_mean = 0.69500 if (order2_help==5.5)

										
									*Bars indicate standard errors of the mean
										gen diff_JDD1_PEER_low = 0.28352 - 0.10861 if (order2_help==1)
										replace diff_JDD1_PEER_low = 0.58815 - 0.09591 if (order2_help==2.25)
										replace diff_JDD1_PEER_low = 0.38095 - 0.12542 if (order2_help==4.25)
										replace diff_JDD1_PEER_low = 0.69500 - 0.09257 if (order2_help==5.5)
										
										gen diff_JDD1_PEER_hi = 0.28352 + 0.10861 if (order2_help==1)
										replace diff_JDD1_PEER_hi = 0.58815 + 0.09591 if (order2_help==2.25)
										replace diff_JDD1_PEER_hi = 0.38095 + 0.12542 if (order2_help==4.25)
										replace diff_JDD1_PEER_hi = 0.69500 + 0.09257 if (order2_help==5.5)
										
																		
					*define (duplicate) mean values for the graph with labels
								gen diff_JDD1_PEER_mean_h=diff_JDD1_PEER_mean*100
								format diff_JDD1_PEER_mean_h %9.0f									
					
															
* Figure 1 Panel A (with value labels)						
						graph twoway (bar diff_JDD1_PEER_mean  order2_help if OTHER==0 , color(gs12) lcolor(black)) (bar diff_JDD1_PEER_mean  order2_help if OTHER==1, color(gs4) lcolor(black)) ///
								(scatter diff_JDD1_PEER_mean  order2_help if OTHER==0 & Treatment_Per2==1 , msymbol(none) ///
								mlabel(diff_JDD1_PEER_mean_h) mlabsize(medsmall) mlabposition(12) mlabgap(*20) mlabcolor(black)) ///
								(scatter diff_JDD1_PEER_mean  order2_help if OTHER==0 & Treatment_Per3==1 , msymbol(none) ///
								mlabel(diff_JDD1_PEER_mean_h) mlabsize(medsmall) mlabposition(12) mlabgap(*20) mlabcolor(black)) ///
								(scatter diff_JDD1_PEER_mean  order2_help if OTHER==1 & Treatment_Per2==1 , msymbol(none) ///
								mlabel(diff_JDD1_PEER_mean_h) mlabsize(medsmall) mlabposition(12) mlabgap(*20) mlabcolor(black)) ///
								(scatter diff_JDD1_PEER_mean  order2_help if OTHER==1 & Treatment_Per3==1 , msymbol(none) ///
								mlabel(diff_JDD1_PEER_mean_h) mlabsize(medsmall) mlabposition(12) mlabgap(*20) mlabcolor(black)) ///
								(rcap  diff_JDD1_PEER_hi  diff_JDD1_PEER_low  order2_help, color(black)), ///
								yscale(r(-0.2 1)) ylabel(  -0.2 "-20" 0 "0" 0.2 "20" 0.4 "40" 0.6 "60" 0.8 "80", ang(h) nogrid) xscale(r(0 6.5)) ///
								xlabel(1.75 `" "Second decision-"  "makers" "' 5.25 `" "Third decision-"  "makers"  "' , noticks)  ///
								xsize(6) xtitle("", yoffset(-1.5))  legend(off) graphregion(color(white)) yline(0, lcolor(black) lwidth(thin)) ytitle("Diff. in the prevalence of destructive" "choices in JDG b/w DESTRUCTIVE" "PEER and PEACEFUL PEER") title(Overall peer effect)
								*graph end	
								
								
***************************************************************************************************************************************		
****************************** FIGURE 1 PANEL B: Susceptibility to follow destructive behavior ************************************************		
*****************************************************************************************************************************************


use "Data_Social_contagion_Study1.dta", clear
set more off

***difference Treatment_Per2 DESTRUCTIVE PEER -NO_PEER
	ttest JDD1 if OTHER==0 & (NO_PEER==1 | (Treatment_Per2==1 & DESTRUCTIVE_PEER==1)), by(Treatment_Per2)
	ttest JDD1 if OTHER==1 & (NO_PEER==1 | (Treatment_Per2==1 & DESTRUCTIVE_PEER==1)), by(Treatment_Per2)
***difference Treatment_Per3 DESTRUCTIVE PEER -NO_PEER	
	ttest JDD1 if OTHER==0 & (NO_PEER==1 | (Treatment_Per3==1 & DESTRUCTIVE_PEER==1)), by(Treatment_Per3)
	ttest JDD1 if OTHER==1 & (NO_PEER==1 | (Treatment_Per3==1 & DESTRUCTIVE_PEER==1)), by(Treatment_Per3)
	
	
		***export values for the differences (means and standard errors)
			reg JDD1 Treatment_Per2 if OTHER==0 & (NO_PEER==1 | (Treatment_Per2==1 & DESTRUCTIVE_PEER==1))
			outreg2 using "Tables_Figures_Paper\Figure_1_PanelB_values.xls", replace dec(5) stats(coef se N) level(90) noparen
			reg JDD1 Treatment_Per2 if OTHER==1 & (NO_PEER==1 | (Treatment_Per2==1 & DESTRUCTIVE_PEER==1))
			outreg2
			reg JDD1 Treatment_Per3 if OTHER==0 & (NO_PEER==1 | (Treatment_Per3==1 & DESTRUCTIVE_PEER==1))
			outreg2 
			reg JDD1 Treatment_Per3 if OTHER==1 & (NO_PEER==1 | (Treatment_Per3==1 & DESTRUCTIVE_PEER==1))
			outreg2
	

					*define graph values, using the values from the excel file above
									gen order2_help=1 if  OTHER==0 & Treatment_Per2==1 
									replace order2_help=2.25 if OTHER==1 & Treatment_Per2==1 	
									replace order2_help=4.25 if  OTHER==0 & Treatment_Per3==1 
									replace order2_help=5.5 if OTHER==1 & Treatment_Per3==1 
																
									*means
									gen diff_JDD1_DESTRNPO_mean = 0.04131 if (order2_help==1)
									replace diff_JDD1_DESTRNPO_mean = 0.35527 if (order2_help==2.25)
									replace diff_JDD1_DESTRNPO_mean = 0.19369 if (order2_help==4.25)
									replace diff_JDD1_DESTRNPO_mean = 0.45608 if (order2_help==5.5)

										
									*Bars indicate standard errors of the mean
										gen diff_JDD1_DESTRNPO_low = 0.04131 - 0.10341 if (order2_help==1)
										replace diff_JDD1_DESTRNPO_low = 0.35527 - 0.10205 if (order2_help==2.25)
										replace diff_JDD1_DESTRNPO_low = 0.19369 - 0.13125 if (order2_help==4.25)
										replace diff_JDD1_DESTRNPO_low = 0.45608 - 0.10892 if (order2_help==5.5)
										
										gen diff_JDD1_DESTRNPO_hi = 0.04131 + 0.10341 if (order2_help==1)
										replace diff_JDD1_DESTRNPO_hi = 0.35527 + 0.10205 if (order2_help==2.25)
										replace diff_JDD1_DESTRNPO_hi = 0.19369 + 0.13125 if (order2_help==4.25)
										replace diff_JDD1_DESTRNPO_hi = 0.45608 + 0.10892 if (order2_help==5.5)
										
																		
					*define (duplicate) mean values for the graph with labels
								gen diff_JDD1_DESTRNPO_mean_h=diff_JDD1_DESTRNPO_mean*100
								format diff_JDD1_DESTRNPO_mean_h %9.0f									
					
															
* Figure 1 Panel B (with value labels)						
						graph twoway (bar diff_JDD1_DESTRNPO_mean  order2_help if OTHER==0 , color(gs12) lcolor(black)) (bar diff_JDD1_DESTRNPO_mean  order2_help if OTHER==1, color(gs4) lcolor(black)) ///
								(scatter diff_JDD1_DESTRNPO_mean  order2_help if OTHER==0 & Treatment_Per2==1, msymbol(none) ///
								mlabel(diff_JDD1_DESTRNPO_mean_h) mlabsize(medsmall) mlabposition(12) mlabgap(*20) mlabcolor(black)) ///
								(scatter diff_JDD1_DESTRNPO_mean  order2_help if OTHER==0 & Treatment_Per3==1, msymbol(none) ///
								mlabel(diff_JDD1_DESTRNPO_mean_h) mlabsize(medsmall) mlabposition(12) mlabgap(*20) mlabcolor(black)) ///
								(scatter diff_JDD1_DESTRNPO_mean  order2_help if OTHER==1 & Treatment_Per2==1, msymbol(none) ///
								mlabel(diff_JDD1_DESTRNPO_mean_h) mlabsize(medsmall) mlabposition(12) mlabgap(*20) mlabcolor(black)) ///
								(scatter diff_JDD1_DESTRNPO_mean  order2_help if OTHER==1 & Treatment_Per3==1, msymbol(none) ///
								mlabel(diff_JDD1_DESTRNPO_mean_h) mlabsize(medsmall) mlabposition(12) mlabgap(*20) mlabcolor(black)) ///
								(rcap  diff_JDD1_DESTRNPO_hi  diff_JDD1_DESTRNPO_low  order2_help, color(black)), ///
								yscale(r(-0.2 1)) ylabel(  -0.2 "-20" 0 "0" 0.2 "20" 0.4 "40" 0.6 "60" 0.8 "80", ang(h) nogrid) xscale(r(0 6.5)) ///
								xlabel(1.75 `" "Second decision-"  "makers" "' 5.25 `" "Third decision-"  "makers"  "' , noticks)  ///
								xsize(6) xtitle("", yoffset(-1.5))  legend( row(1) order(1 "SAME" 2 "OTHER")) graphregion(color(white)) yline(0, lcolor(black) lwidth(thin)) ytitle("Diff. in the prevalence of destructive" "choices in JDG b/w DESTRUCTIVE" "PEER and NO PEER") title(Susceptibility to follow destructive behavior)
								*graph end
								
***************************************************************************************************************************************		
****************************** FIGURE S2 PANEL A: Second decision-makers ************************************************		
*****************************************************************************************************************************************
use "Data_Social_contagion_Study1.dta", clear
set more off

***Second decision-makers, by treatment
		ttest JDD1 if OTHER==0 & Treatment_Per2==1, by(DESTRUCTIVE_PEER)
		ttest JDD1 if OTHER==1 & Treatment_Per2==1, by(DESTRUCTIVE_PEER)

	
					*define graph values, using the values from the excel file above
									gen order2_help=1 if  OTHER==0 & Treatment_Per2==1 & DESTRUCTIVE_PEER==0
									replace order2_help=2.25 if  OTHER==0 & Treatment_Per2==1 & DESTRUCTIVE_PEER==1
									replace order2_help=4.25 if  OTHER==1 & Treatment_Per2==1 & DESTRUCTIVE_PEER==0
									replace order2_help=5.5 if OTHER==1 & Treatment_Per2==1 & DESTRUCTIVE_PEER==1	
																
									*means
									gen diff_JDD1_PEER_mean = .2307692  if (order2_help==1)
									replace diff_JDD1_PEER_mean = .5142857 if (order2_help==2.25)
									replace diff_JDD1_PEER_mean = .1860465 if (order2_help==4.25)
									replace diff_JDD1_PEER_mean = .7741935 if (order2_help==5.5)

										
									*Bars indicate standard errors of the mean
										gen diff_JDD1_PEER_low = .2307692  - .0683479  if (order2_help==1)
										replace diff_JDD1_PEER_low = .5142857 - .0857143  if (order2_help==2.25)
										replace diff_JDD1_PEER_low = .1860465 - .0600463 if (order2_help==4.25)
										replace diff_JDD1_PEER_low = .7741935 - .0763365  if (order2_help==5.5)
										
										gen diff_JDD1_PEER_hi = .2307692  + .0683479  if (order2_help==1)
										replace diff_JDD1_PEER_hi = .5142857 + .0857143  if (order2_help==2.25)
										replace diff_JDD1_PEER_hi = .1860465 + .0600463 if (order2_help==4.25)
										replace diff_JDD1_PEER_hi = .7741935 + .0763365  if (order2_help==5.5)
										
																		
					*define (duplicate) mean values for the graph with labels
								gen diff_JDD1_PEER_mean_h=diff_JDD1_PEER_mean*100
								format diff_JDD1_PEER_mean_h %9.0f									
					
															
* Figure S2 Panel A (with value labels)						
						graph twoway (bar diff_JDD1_PEER_mean  order2_help if OTHER==0 , color(gs12) lcolor(black)) (bar diff_JDD1_PEER_mean  order2_help if OTHER==1, color(gs4) lcolor(black)) ///
								(scatter diff_JDD1_PEER_mean  order2_help if OTHER==0 & DESTRUCTIVE_PEER==0, msymbol(none) ///
								mlabel(diff_JDD1_PEER_mean_h) mlabsize(medsmall) mlabposition(12) mlabgap(*20) mlabcolor(black)) ///
								(scatter diff_JDD1_PEER_mean  order2_help if OTHER==0 & DESTRUCTIVE_PEER==1, msymbol(none) ///
								mlabel(diff_JDD1_PEER_mean_h) mlabsize(medsmall) mlabposition(12) mlabgap(*20) mlabcolor(black)) ///
								(scatter diff_JDD1_PEER_mean  order2_help if OTHER==1 & DESTRUCTIVE_PEER==0, msymbol(none) ///
								mlabel(diff_JDD1_PEER_mean_h) mlabsize(medsmall) mlabposition(12) mlabgap(*20) mlabcolor(black)) ///
								(scatter diff_JDD1_PEER_mean  order2_help if OTHER==1 & DESTRUCTIVE_PEER==1, msymbol(none) ///
								mlabel(diff_JDD1_PEER_mean_h) mlabsize(medsmall) mlabposition(12) mlabgap(*20) mlabcolor(black)) ///
								(rcap  diff_JDD1_PEER_hi  diff_JDD1_PEER_low  order2_help, color(black)), ///
								yscale(r(0 1.2)) ylabel(0 "0" 0.2 "20" 0.4 "40" 0.6 "60" 0.8 "80" 1 "100", ang(h) nogrid) xscale(r(0 6.5)) ///
								xlabel(1 `" "PEACEFUL"  "PEER" "' 2.25 `" "DESTRUCTIVE"  "PEER"  "' 4.25 `" "PEACEFUL"  "PEER" "' 5.5 `" "DESTRUCTIVE"  "PEER"  "', noticks)  ///
								xsize(6) xtitle("", yoffset(-1.5))  legend( row(1) order(1 "SAME" 2 "OTHER")) graphregion(color(white)) yline(0, lcolor(black) lwidth(thin)) ytitle("Prevalence of destructive choices (%)") title("Second decision-makers")
								*graph end	

								
***************************************************************************************************************************************		
****************************** FIGURE S2 PANEL B: Third decision-makers ************************************************		
*****************************************************************************************************************************************
use "Data_Social_contagion_Study1.dta", clear
set more off

***Third decision-makers, by treatment
		ttest JDD1 if OTHER==0 & Treatment_Per3==1, by(DESTRUCTIVE_PEER)
		ttest JDD1 if OTHER==1 & Treatment_Per3==1, by(DESTRUCTIVE_PEER)

		
					*define graph values, using the values from the excel file above
									gen order2_help=1 if  OTHER==0 & Treatment_Per3==1 & DESTRUCTIVE_PEER==0
									replace order2_help=2.25 if  OTHER==0 & Treatment_Per3==1 & DESTRUCTIVE_PEER==1
									replace order2_help=4.25 if  OTHER==1 & Treatment_Per3==1 & DESTRUCTIVE_PEER==0
									replace order2_help=5.5 if OTHER==1 & Treatment_Per3==1 & DESTRUCTIVE_PEER==1	
																
									*means
									gen diff_JDD1_PEER_mean = .2857143   if (order2_help==1)
									replace diff_JDD1_PEER_mean = .6666667  if (order2_help==2.25)
									replace diff_JDD1_PEER_mean = .18 if (order2_help==4.25)
									replace diff_JDD1_PEER_mean = .875 if (order2_help==5.5)

										
									*Bars indicate standard errors of the mean
										gen diff_JDD1_PEER_low = .2857143   - .0609145   if (order2_help==1)
										replace diff_JDD1_PEER_low = .6666667  - .1143324   if (order2_help==2.25)
										replace diff_JDD1_PEER_low = .18 - .0548839  if (order2_help==4.25)
										replace diff_JDD1_PEER_low = .875 - .0689597  if (order2_help==5.5)
										
										gen diff_JDD1_PEER_hi = .2857143   + .0609145  if (order2_help==1)
										replace diff_JDD1_PEER_hi = .6666667  + .1143324   if (order2_help==2.25)
										replace diff_JDD1_PEER_hi = .18 + .0548839  if (order2_help==4.25)
										replace diff_JDD1_PEER_hi = .875 + .0689597  if (order2_help==5.5)
										
																		
					*define (duplicate) mean values for the graph with labels
								gen diff_JDD1_PEER_mean_h=diff_JDD1_PEER_mean*100
								format diff_JDD1_PEER_mean_h %9.0f									
					
															
* Figure S2 Panel B (with value labels)						
						graph twoway (bar diff_JDD1_PEER_mean  order2_help if OTHER==0 , color(gs12) lcolor(black)) (bar diff_JDD1_PEER_mean  order2_help if OTHER==1, color(gs4) lcolor(black)) ///
								(scatter diff_JDD1_PEER_mean  order2_help if OTHER==0 & DESTRUCTIVE_PEER==0, msymbol(none) ///
								mlabel(diff_JDD1_PEER_mean_h) mlabsize(medsmall) mlabposition(12) mlabgap(*20) mlabcolor(black)) ///
								(scatter diff_JDD1_PEER_mean  order2_help if OTHER==0 & DESTRUCTIVE_PEER==1, msymbol(none) ///
								mlabel(diff_JDD1_PEER_mean_h) mlabsize(medsmall) mlabposition(12) mlabgap(*20) mlabcolor(black)) ///
								(scatter diff_JDD1_PEER_mean  order2_help if OTHER==1 & DESTRUCTIVE_PEER==0, msymbol(none) ///
								mlabel(diff_JDD1_PEER_mean_h) mlabsize(medsmall) mlabposition(12) mlabgap(*20) mlabcolor(black)) ///
								(scatter diff_JDD1_PEER_mean  order2_help if OTHER==1 & DESTRUCTIVE_PEER==1, msymbol(none) ///
								mlabel(diff_JDD1_PEER_mean_h) mlabsize(medsmall) mlabposition(12) mlabgap(*20) mlabcolor(black)) ///
								(rcap  diff_JDD1_PEER_hi  diff_JDD1_PEER_low  order2_help, color(black)), ///
								yscale(r(0 1.2)) ylabel(0 "0" 0.2 "20" 0.4 "40" 0.6 "60" 0.8 "80" 1 "100", ang(h) nogrid) xscale(r(0 6.5)) ///
								xlabel(1 `" "PEACEFUL"  "PEER" "' 2.25 `" "DESTRUCTIVE"  "PEER"  "' 4.25 `" "PEACEFUL"  "PEER" "' 5.5 `" "DESTRUCTIVE"  "PEER"  "', noticks)  ///
								xsize(6) xtitle("", yoffset(-1.5))  legend( row(1) order(1 "SAME" 2 "OTHER")) graphregion(color(white)) yline(0, lcolor(black) lwidth(thin)) ytitle("Prevalence of destructive choices (%)") title("Third decision-makers")
								*graph end	
